function y = interpolate(v);
%
%
%
nc = length(v)-1;
nf = 2*nc;

y = zeros(nf+1,1);
y(3:2:nf-1) = v(2:nc);
y(2:2:nf)   = 0.5*(v(1:nc)+v(2:nc+1));
y(1) = 0;   y(nf+1) = 0;



